/*
 * @Author: szx
 * @Date: 2021-11-26 12:53:26
 * @LastEditTime: 2021-11-26 12:57:41
 * @Description:
 * @FilePath: \leetcode\200-299\201\201.js
 */
/**
 * @param {number} left
 * @param {number} right
 * @return {number}
 */
const rangeBitwiseAnd = function (m, n) {
    let shift = 0;
    // 找到公共前缀
    while (m < n) {
        m >>= 1;
        n >>= 1;
        ++shift;
    }
    return m << shift;
};
